<%@ page contentType="text/html; charset=UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsf/html" prefix="h"%>
<%@ taglib uri="http://java.sun.com/jsf/core" prefix="f"%>
<%@ taglib uri="http://richfaces.org/a4j" prefix="a4j"%>
<%@ taglib uri="http://richfaces.org/rich" prefix="rich"%>
<%
	String contextRoot = request.getContextPath();
%>
<f:loadBundle basename="properties.messages" var="msg" />
<f:view>
	<!doctype html>
	<head>
	<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
	<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
	<title>SISDEP : Sistema de Informaci<h:outputText value="#{msg.tilde_o}" />n de Espacio P<h:outputText value="#{msg.tilde_u}" />blico</title>
	<meta name="description" content="">
	<meta name="author" content="">
	<link rel="stylesheet" href="<%=contextRoot%>/css/validationEngine.jquery.css" type="text/css">
	<link rel="stylesheet" href="<%=contextRoot%>/css/normalize.css">
	<link rel="stylesheet" href="<%=contextRoot%>/css/uniform.css"> <!-- estilos formularios -->
	<link rel="stylesheet" href="<%=contextRoot%>/css/cuerpo.css">
	<link rel="stylesheet" href="<%=contextRoot%>/css/richCustom.css">	
	</head>
	<body>
	<div id="marco"><!--inicio contenedor -->
	<div class="arriba-cuerpo"></div>
	<!-- Burrada pa ver borde redondo en IE -->
	<div class="cuerpo"><a href="<%=contextRoot%>/index.jsf"><img src="<%= contextRoot %>/images/logos.png" /></a>
	<div class="clear"></div>
	<!-- Menu y Usuario init() --> <%@ include
		file="include/menuUsuario.jsp"%> <!-- Menu y Usuario end() -->
	<div class="clear"></div>
	<!-- Formulario -->
	<div id="buscador">
	<h2>Gesti<h:outputText value="#{msg.tilde_o}" />n de Estudio Socio Econ<h:outputText value="#{msg.tilde_o}" />mico: <h:outputText value="#{estSocioEconomicoController.estSocioEconomico.id ne '' ? 'EDICION' : 'NUEVO'}" /></h2>
	<!-- 
	inclusion de campos de formularios init()
	-->
 	<div style="position: relative; float: right;">
		<div class="currentStep<h:outputText value="#{estSocioEconomicoController.estSocioEconomicoDetalle.opcion eq '1' ? 'h' : ''}" />">1</div>
		<div class="currentStep<h:outputText value="#{estSocioEconomicoController.estSocioEconomicoDetalle.opcion eq '2' ? 'h' : ''}" />">2</div>
		<div class="currentStep<h:outputText value="#{estSocioEconomicoController.estSocioEconomicoDetalle.opcion eq '3' ? 'h' : ''}" />">3</div>
		<div class="currentStep<h:outputText value="#{estSocioEconomicoController.estSocioEconomicoDetalle.opcion eq '4' ? 'h' : ''}" />">4</div>
		<div class="currentStep<h:outputText value="#{estSocioEconomicoController.estSocioEconomicoDetalle.opcion eq '5' ? 'h' : ''}" />">5</div>
		<div class="currentStep<h:outputText value="#{estSocioEconomicoController.estSocioEconomicoDetalle.opcion eq '6' ? 'h' : ''}" />">6</div>
		<div class="currentStep<h:outputText value="#{estSocioEconomicoController.estSocioEconomicoDetalle.opcion eq '7' ? 'h' : ''}" />">7</div>
	</div><br/><br/>
	<div class="clear"></div>
	<h:form id="updateEstCondViviendaForm">
		<h:inputHidden id="estCondVivienda_id" value="#{estSocioEconomicoController.estSocioEconomicoDetalle.estCondVivienda.id}" />
		<h:inputHidden id="estCondVivienda_idEstSocioEconomico" value="#{estSocioEconomicoController.estSocioEconomicoDetalle.estCondVivienda.idEstSocioEconomico}" />

		<h3>2. Condiciones de la vivienda</h3>

		<span class="left">
			<label>Propiedad de la vivienda<span class="asterisco">*</span></label>
			<h:selectOneMenu id="idPropiedadStr" styleClass="validate[required]"
				value="#{estSocioEconomicoController.estSocioEconomicoDetalle.estCondVivienda.idPropiedadStr}">
				<f:selectItem itemLabel="Seleccione..." itemValue="" />
				<f:selectItems value="#{masterListCache.typeOfHousingList}" />
			</h:selectOneMenu>
		</span>

		<span class="left" style="margin-left: 5px">
		<label>Otro </label>
			<h:inputText id="estCondVivienda_propiedadOtro" size="128" maxlength="128"
			styleClass="validate[maxSize[128]]"
			style="width:150px !important; min-width:150px !important; max-width:150px !important;"
			value="#{estSocioEconomicoController.estSocioEconomicoDetalle.estCondVivienda.propiedadOtro}" />
		</span>

		<span class="left" style="margin-left: 5px">
			<label>Valor del arriendo </label> 
			<h:inputText
				id="estCondVivienda_valorArriendo" size="9" maxlength="9" styleClass="validate[custom[integer],maxSize[9]]"
				value="#{estSocioEconomicoController.estSocioEconomicoDetalle.estCondVivienda.valorArriendo}" />
		</span>

		<div class="clear" style="margin-left: 400px;"></div>

		<span class="left" style="margin-left: 0px">
			<label>Tipo de vivienda<span class="asterisco">*</span></label>
			<h:selectOneMenu id="estCondVivienda_idTipoStr" styleClass="validate[required]"
				value="#{estSocioEconomicoController.estSocioEconomicoDetalle.estCondVivienda.idTipoStr}">
				<f:selectItem itemLabel="Seleccione..." itemValue="" />
				<f:selectItems value="#{masterListCache.typeClassOfHousingList}" />
			</h:selectOneMenu>			
		</span>

		<span class="left" style="margin-left: 5px;"> 
		<label>Otro</label>
		<h:inputText id="estCondVivienda_tipoOtro" styleClass=""
			style="width:150px !important; min-width:150px !important; max-width:150px;"
			value="#{estSocioEconomicoController.estSocioEconomicoDetalle.estCondVivienda.tipoOtro}" />
		</span>

		<div class="clear" style="margin-left: 400px;"></div>

		<span class="left" style="margin-left: 0px; width: 170px;"> <label>N<h:outputText value="#{msg.tilde_u}" />mero de Casas <span
			class="asterisco"> </span></label> <h:inputText id="estCondVivienda_numeroCasa" size="9"
			maxlength="9" styleClass="validate[custom[integer],maxSize[9]]"
			value="#{estSocioEconomicoController.estSocioEconomicoDetalle.estCondVivienda.numeroCasa}" />
		</span>


		<span class="left" style="margin-left: 40px; width: 170px;"> <label>N<h:outputText value="#{msg.tilde_u}" />mero de Apartamentos <span
			class="asterisco"> </span></label> <h:inputText id="estCondVivienda_numeroApartamento"
			size="9" maxlength="9" styleClass="validate[custom[integer],maxSize[9]]"
			value="#{estSocioEconomicoController.estSocioEconomicoDetalle.estCondVivienda.numeroApartamento}" />
		</span>

		<span class="left" style="margin-left: 40px; width: 170px;"> <label>N<h:outputText value="#{msg.tilde_u}" />mero de Locales <span
			class="asterisco"> </span></label> <h:inputText id="estCondVivienda_numeroLocal" size="9"
			maxlength="9" styleClass="validate[custom[integer],maxSize[9]]"
			value="#{estSocioEconomicoController.estSocioEconomicoDetalle.estCondVivienda.numeroLocal}" />
		</span>

		<div class="clear" style="margin-left: 400px;"></div>

		<span class="left"> <label>Valor Ingreso Por Renta <span
			class="asterisco">*</span></label> <h:inputText id="estCondVivienda_valorIngresoRenta"
			size="9" maxlength="9" styleClass="validate[required,custom[integer],maxSize[9]]"
			value="#{estSocioEconomicoController.estSocioEconomicoDetalle.estCondVivienda.valorIngresoRenta}" />
		</span>

		<div class="clear" style="margin-left: 400px;"></div>
		<p><em class="left">Presione CTRL, para seleccionar varios items en la lista de servicios p<h:outputText value="#{msg.tilde_u}" />blicos</em><br/></p>
		<div class="clear" style="margin-left: 400px;"></div>

		<span class="left" style="margin-left: 5px;"> 
		<label>Servicios P<h:outputText value="#{msg.tilde_u}" />blicos domiciliarios <span class="asterisco">*</span></label> 
			<h:selectManyListbox 
				id="estCondVivienda_servicioPublico" 
				value="#{estSocioEconomicoController.estSocioEconomicoDetalle.servicioPublicoCheckItem}"
				style="width: 400px; height: 150px;" 
				styleClass="validate[required]" size="5">
					<f:selectItem itemLabel="Seleccione..." itemValue="" />
   					<f:selectItem itemValue="E" itemLabel="Energ#{msg.tilde_i}a" />
   					<f:selectItem itemValue="A" itemLabel="Acueducto" />
   					<f:selectItem itemValue="C" itemLabel="Alcantarillado" />
   					<f:selectItem itemValue="G" itemLabel="Gas Natural" />
   					<f:selectItem itemValue="T" itemLabel="Tel#{msg.tilde_e}fono" />
   					<f:selectItem itemValue="V" itemLabel="TV Cable" />
   					<f:selectItem itemValue="I" itemLabel="Internet" />
   					<f:selectItem itemValue="U" itemLabel="Acueducto comunitario" />
   					<f:selectItem itemValue="P" itemLabel="Pozo S#{msg.tilde_e}ptico" />
   					<f:selectItem itemValue="O" itemLabel="Otro" />
   			</h:selectManyListbox>
		</span>

		<div class="clear" style="margin-left: 400px;"></div>

		<span class="left" style="margin-left: 5px; width:300px !important; min-width:300px !important; max-width:300px !important; height:100px !important; min-height:100px !important; max-height:100px !important;">
		<label>Otro Servicio Publico </label> 
		<h:inputTextarea id="estCondVivienda_otroServicioPublico" cols="90" rows="3" styleClass=""
			style="width:300px !important; min-width:300px !important; max-width:300px !important; height:60px !important; min-height:60px !important; max-height:60px !important; "
			value="#{estSocioEconomicoController.estSocioEconomicoDetalle.estCondVivienda.otroServicioPublico}" />
		</span>

		<div class="clear" style="margin-left: 400px;"></div>

		<span class="left" style="margin-left: 5px;" > 
		<label>Observaci<h:outputText value="#{msg.tilde_o}" />n </label> 
		<h:inputTextarea id="estCondVivienda_observacion" cols="90" rows="3" styleClass="" 
			style="width:300px !important; min-width:300px !important; max-width:300px !important; height:60px !important; min-height:60px !important; max-height:60px !important;"
			value="#{estSocioEconomicoController.estSocioEconomicoDetalle.estCondVivienda.observacion}" />
		</span>

		<div class="clear" style="margin-left: 400px;"></div>

		<span class="left" style="margin-left: 5px"> <label>Estado
		<span class="asterisco">*</span></label> <h:selectOneMenu id="estCondVivienda_estado"
			styleClass="validate[required]"
			value="#{estSocioEconomicoController.estSocioEconomicoDetalle.estCondVivienda.estado}">
			<f:selectItem itemLabel="Seleccione..." itemValue="" />
			<f:selectItem itemLabel="Pendiente" itemValue="PENDIENTE" />
			<f:selectItem itemLabel="Diligenciado" itemValue="DILIGENCIADO" />
			<f:selectItem itemLabel="Confirmado" itemValue="CONFIRMADO" />
		</h:selectOneMenu>
		</span>
		
		<div class="clear"></div>
		(<span class="asterisco"> * </span>) : Campo Obligatorio
		<div class="clear"></div>
		<span class="botones right">		
		<h:commandButton
			id="updateEstCondViviendaButton" styleClass="botonsmall"
			type="submit" value="Continuar" ondblclick="return false;"
			action="#{estSocioEconomicoController.updateDetailEstCondVivienda}">
		</h:commandButton>
		</span>
		<!--
			inclusion de campos entregados por el generador end()
		-->
	</h:form>
	<h:form id="cancelEstCondViviendaForm">
		<span class="botones left">		
		<h:commandButton
			id="cancelEstCondViviendaButton" styleClass="botonsmall"
			type="submit" value="Volver" ondblclick="return false;"
			action="#{estSocioEconomicoController.cancelDetailEstCondVivienda}">
		</h:commandButton>
		</span>
	</h:form>


	<!--
	inclusion de campos de formularios end()
 	-->
 	
 	</div>
	<!-- Fin formulario -->
	<div class="clear"></div>
	<!-- tabla -->
	<div class="clear" style="width: 400px; margin-left: 0px;"></div>
	<br />
	<span class="botones left"
		style="width: 223px; height: 15px; margin-left: 5px; padding-top: 5px; padding-bottom: 5px; padding-left: 20px; padding-right: 20px; background-color: #006F73; color: white;">
	Informaci<h:outputText value="#{msg.tilde_o}" />n de Auditor<h:outputText
		value="#{msg.tilde_i}" />a </span>
	<div class="clear" style="margin-left: 400px;"></div>
	<div><span class="left"> <span class="left"
		style="width: 110px; height: 15px; margin-left: 5px; padding-top: 5px; padding-bottom: 5px; padding-left: 10px; padding-right: 10px; background-color: #EDEDED; border-top: 1px solid #999999; border-bottom: 1px solid #999999; border-left: 1px solid #999999; border-right: 1px solid #999999; color: #666666;">Usuario
	Creaci<h:outputText value="#{msg.tilde_o}" />n</span> <span class="left"
		style="width: 110px; height: 15px; margin-left: 0px; padding-top: 5px; padding-bottom: 5px; padding-left: 10px; padding-right: 10px; background-color: #EDEDED; border-top: 1px solid #999999; border-bottom: 1px solid #999999; border-left: 0px solid #999999; border-right: 1px solid #999999; color: #666666;">Fecha
	Creaci<h:outputText value="#{msg.tilde_o}" />n</span> <span class="left"
		style="width: 170px; height: 15px; margin-left: 0px; padding-top: 5px; padding-bottom: 5px; padding-left: 10px; padding-right: 10px; background-color: #EDEDED; border-top: 1px solid #999999; border-bottom: 1px solid #999999; border-left: 0px solid #999999; border-right: 1px solid #999999; color: #666666;">Usuario
	<h:outputText value="#{msg.tilde_u}" />ltima Modificaci<h:outputText
		value="#{msg.tilde_o}" />n</span> <span class="left"
		style="width: 170px; height: 15px; margin-left: 0px; padding-top: 5px; padding-bottom: 5px; padding-left: 10px; padding-right: 10px; background-color: #EDEDED; border-top: 1px solid #999999; border-bottom: 1px solid #999999; border-left: 0px solid #999999; border-right: 1px solid #999999; color: #666666;">Fecha
	<h:outputText value="#{msg.tilde_u}" />ltima Modificaci<h:outputText
		value="#{msg.tilde_o}" />n</span> </span>
	<span class="left"> <span class="left"
		style="width: 110px; height: 15px; margin-left: 5px; padding-top: 5px; padding-bottom: 5px; padding-left: 10px; padding-right: 10px; background-color: #ffffff; border-top: 0px solid #999999; border-bottom: 1px solid #999999; border-left: 1px solid #999999; border-right: 1px solid #999999; color: #666666;"><h:outputText
		value="#{estSocioEconomicoController.estSocioEconomicoDetalle.estCondVivienda.usuarioCrea}" /></span>
	<span class="left"
		style="width: 110px; height: 15px; margin-left: 0px; padding-top: 5px; padding-bottom: 5px; padding-left: 10px; padding-right: 10px; background-color: #ffffff; border-top: 0px solid #999999; border-bottom: 1px solid #999999; border-left: 0px solid #999999; border-right: 1px solid #999999; color: #666666;"><h:outputText
		value="#{estSocioEconomicoController.estSocioEconomicoDetalle.estCondVivienda.fechaCrea}" /></span>
	<span class="left"
		style="width: 170px; height: 15px; margin-left: 0px; padding-top: 5px; padding-bottom: 5px; padding-left: 10px; padding-right: 10px; background-color: #ffffff; border-top: 0px solid #999999; border-bottom: 1px solid #999999; border-left: 0px solid #999999; border-right: 1px solid #999999; color: #666666;"><h:outputText
		value="#{estSocioEconomicoController.estSocioEconomicoDetalle.estCondVivienda.usuarioModifica}" /></span>
	<span class="left"
		style="width: 170px; height: 15px; margin-left: 0px; padding-top: 5px; padding-bottom: 5px; padding-left: 10px; padding-right: 10px; background-color: #ffffff; border-top: 0px solid #999999; border-bottom: 1px solid #999999; border-left: 0px solid #999999; border-right: 1px solid #999999; color: #666666;"><h:outputText
		value="#{estSocioEconomicoController.estSocioEconomicoDetalle.estCondVivienda.fechaModifica}" /></span>
	</span></div>
	<div class="clear"><br />
	</div>
	<div>
	<h:form id="cancelEstSocioEconomicoForm">
		<h:commandButton id="cancelCreateEstSocioEconomicoButton"
			styleClass="botonsmall" type="submit" value="Cancelar"
			ondblclick="return false;"
			action="#{estSocioEconomicoController.cancelEst}">
		</h:commandButton>
	</h:form>
	</div>
	<div id="containerError" style="display:block;">
		<span class="botones left"><h:messages style="font-weight: bold; color: #FF0000;" /></span>
	</div>
	</div>
	<div class="abajo-cuerpo"></div>
	<!-- Burrada pa ver borde redondo en IE --></div>
	<!-- Fin contenedor -->
	<div class="footer"></div>
	<script src="<%=contextRoot%>/js/jquery/lib/jquery-1.7.2.min.js"></script><!-- De ser 1ro -->
	<script src="<%=contextRoot%>/js/script.js" type="text/javascript"></script><!-- De ser 2do -->
	<script src="<%=contextRoot%>/js/jquery/lib/jquery.uniform.min.js"></script> <!-- formularios -->
	<script src="<%=contextRoot%>/js/jquery/lib/jquery.validationEngine.js" type="text/javascript" charset="utf-8"></script>
	<script src="<%=contextRoot%>/js/jquery/lib/jquery.validationEngine-es.js" type="text/javascript" charset="utf-8"></script>
    <script src="<%=contextRoot%>/js/jquery.maskedinput-1.3.js" type="text/javascript"></script>
	<script type="text/javascript">
        jQ(document).ready(function() {
        	jQ("input, select, input:checkbox, input:radio, input:file").uniform();
        	jQ("#updateEstCondViviendaForm").validationEngine('attach');
        	jQ("#updateEstCondViviendaForm").bind("jqv.form.result", 
                	function(event, errorFound) {
					if(!errorFound){ 
            				displayLoadingImage();
        				}
        	});
        });
    </script>
	<%@ include file="include/validationStatus.jsp" %>
	<%@ include file="include/modalMessageWindow.jsp" %>	
	</body>
	</html>
</f:view>
